package com._520it.crm.web.controller;

import com._520it.crm.page.PageResult;
import com._520it.crm.query.CarInfoQueryObject;
import com._520it.crm.service.ICarInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * Created by 呆 on 2017/10/3.
 */
@Controller
@RequestMapping("/car")
public class CarInfoController {
    @Autowired
    private ICarInfoService carInfoService;
    @RequestMapping("")
    public String index(){
        return "carInfo";
    }

    @RequestMapping("/list")
    @ResponseBody
    public PageResult list(CarInfoQueryObject qo){
         return carInfoService.query(qo);
    }


}
